Integrand size = 23, antiderivative size = 161 \[ \int \frac {(a+a \sec (c+d x))^4}{\sqrt {\sec (c+d x)}} \, dx=-\frac {56 a^4 \sqrt {\cos (c+d x)} E\left (\left .\frac {1}{2} (c+d x)\right |2\right ) \sqrt {\sec (c+d x)}}{5 d}+\frac {32 a^4 \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right ) \sqrt {\sec (c+d x)}}{3 d}+\frac {66 a^4 \sqrt {\sec (c+d x)} \sin (c+d x)}{5 d}+\frac {8 a^4 \sec ^{\frac {3}{2}}(c+d x) \sin (c+d x)}{3 d}+\frac {2 a^4 \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{5 d} \]
[Out]
Time = 0.24 (sec) , antiderivative size = 161, normalized size of antiderivative = 1.00, number of steps used = 16, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.217, Rules used = {3876, 3856, 2719, 2720, 3853} \[ \int \frac {(a+a \sec (c+d x))^4}{\sqrt {\sec (c+d x)}} \, dx=\frac {2 a^4 \sin (c+d x) \sec ^{\frac {5}{2}}(c+d x)}{5 d}+\frac {8 a^4 \sin (c+d x) \sec ^{\frac {3}{2}}(c+d x)}{3 d}+\frac {66 a^4 \sin (c+d x) \sqrt {\sec (c+d x)}}{5 d}+\frac {32 a^4 \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )}{3 d}-\frac {56 a^4 \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)} E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{5 d} \]
[In]
[Out]
Rule 2719
Rule 2720
Rule 3853
Rule 3856
Rule 3876
Rubi steps \begin{align*} \text {integral}& = \int \left (\frac {a^4}{\sqrt {\sec (c+d x)}}+4 a^4 \sqrt {\sec (c+d x)}+6 a^4 \sec ^{\frac {3}{2}}(c+d x)+4 a^4 \sec ^{\frac {5}{2}}(c+d x)+a^4 \sec ^{\frac {7}{2}}(c+d x)\right ) \, dx \\ & = a^4 \int \frac {1}{\sqrt {\sec (c+d x)}} \, dx+a^4 \int \sec ^{\frac {7}{2}}(c+d x) \, dx+\left (4 a^4\right ) \int \sqrt {\sec (c+d x)} \, dx+\left (4 a^4\right ) \int \sec ^{\frac {5}{2}}(c+d x) \, dx+\left (6 a^4\right ) \int \sec ^{\frac {3}{2}}(c+d x) \, dx \\ & = \frac {12 a^4 \sqrt {\sec (c+d x)} \sin (c+d x)}{d}+\frac {8 a^4 \sec ^{\frac {3}{2}}(c+d x) \sin (c+d x)}{3 d}+\frac {2 a^4 \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{5 d}+\frac {1}{5} \left (3 a^4\right ) \int \sec ^{\frac {3}{2}}(c+d x) \, dx+\frac {1}{3} \left (4 a^4\right ) \int \sqrt {\sec (c+d x)} \, dx-\left (6 a^4\right ) \int \frac {1}{\sqrt {\sec (c+d x)}} \, dx+\left (a^4 \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \sqrt {\cos (c+d x)} \, dx+\left (4 a^4 \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \frac {1}{\sqrt {\cos (c+d x)}} \, dx \\ & = \frac {2 a^4 \sqrt {\cos (c+d x)} E\left (\left .\frac {1}{2} (c+d x)\right |2\right ) \sqrt {\sec (c+d x)}}{d}+\frac {8 a^4 \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right ) \sqrt {\sec (c+d x)}}{d}+\frac {66 a^4 \sqrt {\sec (c+d x)} \sin (c+d x)}{5 d}+\frac {8 a^4 \sec ^{\frac {3}{2}}(c+d x) \sin (c+d x)}{3 d}+\frac {2 a^4 \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{5 d}-\frac {1}{5} \left (3 a^4\right ) \int \frac {1}{\sqrt {\sec (c+d x)}} \, dx+\frac {1}{3} \left (4 a^4 \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \frac {1}{\sqrt {\cos (c+d x)}} \, dx-\left (6 a^4 \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \sqrt {\cos (c+d x)} \, dx \\ & = -\frac {10 a^4 \sqrt {\cos (c+d x)} E\left (\left .\frac {1}{2} (c+d x)\right |2\right ) \sqrt {\sec (c+d x)}}{d}+\frac {32 a^4 \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right ) \sqrt {\sec (c+d x)}}{3 d}+\frac {66 a^4 \sqrt {\sec (c+d x)} \sin (c+d x)}{5 d}+\frac {8 a^4 \sec ^{\frac {3}{2}}(c+d x) \sin (c+d x)}{3 d}+\frac {2 a^4 \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{5 d}-\frac {1}{5} \left (3 a^4 \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \sqrt {\cos (c+d x)} \, dx \\ & = -\frac {56 a^4 \sqrt {\cos (c+d x)} E\left (\left .\frac {1}{2} (c+d x)\right |2\right ) \sqrt {\sec (c+d x)}}{5 d}+\frac {32 a^4 \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right ) \sqrt {\sec (c+d x)}}{3 d}+\frac {66 a^4 \sqrt {\sec (c+d x)} \sin (c+d x)}{5 d}+\frac {8 a^4 \sec ^{\frac {3}{2}}(c+d x) \sin (c+d x)}{3 d}+\frac {2 a^4 \sec ^{\frac {5}{2}}(c+d x) \sin (c+d x)}{5 d} \\ \end{align*}
Result contains higher order function than in optimal. Order 5 vs. order 4 in optimal.
Time = 6.15 (sec) , antiderivative size = 286, normalized size of antiderivative = 1.78 \[ \int \frac {(a+a \sec (c+d x))^4}{\sqrt {\sec (c+d x)}} \, dx=\frac {a^4 \sec ^8\left (\frac {1}{2} (c+d x)\right ) (1+\sec (c+d x))^4 \left (-\frac {8 i \sqrt {2} e^{-i (c+d x)} \sqrt {\frac {e^{i (c+d x)}}{1+e^{2 i (c+d x)}}} \cos ^4(c+d x) \left (21 \left (1+e^{2 i (c+d x)}\right )+21 \left (-1+e^{2 i c}\right ) \sqrt {1+e^{2 i (c+d x)}} \operatorname {Hypergeometric2F1}\left (-\frac {1}{4},\frac {1}{2},\frac {3}{4},-e^{2 i (c+d x)}\right )+20 e^{i (c+d x)} \left (-1+e^{2 i c}\right ) \sqrt {1+e^{2 i (c+d x)}} \operatorname {Hypergeometric2F1}\left (\frac {1}{4},\frac {1}{2},\frac {5}{4},-e^{2 i (c+d x)}\right )\right )}{-1+e^{2 i c}}+\frac {-3 (-61+5 \cos (2 c)) \cos (d x) \csc (c)+30 \cos (c) \sin (d x)+2 (20+3 \sec (c+d x)) \tan (c+d x)}{\sec ^{\frac {7}{2}}(c+d x)}\right )}{240 d} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. \(385\) vs. \(2(189)=378\).
Time = 32.19 (sec) , antiderivative size = 386, normalized size of antiderivative = 2.40
method | result | size |
default | \(-\frac {a^{4} \sqrt {-\left (-2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}\, \left (\frac {328 \sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \sqrt {-2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1}\, \operatorname {EllipticF}\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right )}{15 \sqrt {-2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}+\sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}}-\frac {56 \sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \sqrt {-2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1}\, \left (\operatorname {EllipticF}\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right )-\operatorname {EllipticE}\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right )\right )}{5 \sqrt {-2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}+\sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}}-\frac {132 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} \cos \left (\frac {d x}{2}+\frac {c}{2}\right )}{5 \sqrt {-\left (-2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}}-\frac {4 \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \sqrt {-2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}+\sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}}{3 \left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-\frac {1}{2}\right )^{2}}-\frac {\cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \sqrt {-2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}+\sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}}{10 \left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-\frac {1}{2}\right )^{3}}\right )}{\sin \left (\frac {d x}{2}+\frac {c}{2}\right ) \sqrt {2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-1}\, d}\) | \(386\) |
parts | \(\text {Expression too large to display}\) | \(1031\) |
[In]
[Out]
Result contains higher order function than in optimal. Order 9 vs. order 4.
Time = 0.11 (sec) , antiderivative size = 202, normalized size of antiderivative = 1.25 \[ \int \frac {(a+a \sec (c+d x))^4}{\sqrt {\sec (c+d x)}} \, dx=-\frac {2 \, {\left (40 i \, \sqrt {2} a^{4} \cos \left (d x + c\right )^{2} {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right ) - 40 i \, \sqrt {2} a^{4} \cos \left (d x + c\right )^{2} {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right ) + 42 i \, \sqrt {2} a^{4} \cos \left (d x + c\right )^{2} {\rm weierstrassZeta}\left (-4, 0, {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right )\right ) - 42 i \, \sqrt {2} a^{4} \cos \left (d x + c\right )^{2} {\rm weierstrassZeta}\left (-4, 0, {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right )\right ) - \frac {{\left (99 \, a^{4} \cos \left (d x + c\right )^{2} + 20 \, a^{4} \cos \left (d x + c\right ) + 3 \, a^{4}\right )} \sin \left (d x + c\right )}{\sqrt {\cos \left (d x + c\right )}}\right )}}{15 \, d \cos \left (d x + c\right )^{2}} \]
[In]
[Out]
Timed out. \[ \int \frac {(a+a \sec (c+d x))^4}{\sqrt {\sec (c+d x)}} \, dx=\text {Timed out} \]
[In]
[Out]
\[ \int \frac {(a+a \sec (c+d x))^4}{\sqrt {\sec (c+d x)}} \, dx=\int { \frac {{\left (a \sec \left (d x + c\right ) + a\right )}^{4}}{\sqrt {\sec \left (d x + c\right )}} \,d x } \]
[In]
[Out]
\[ \int \frac {(a+a \sec (c+d x))^4}{\sqrt {\sec (c+d x)}} \, dx=\int { \frac {{\left (a \sec \left (d x + c\right ) + a\right )}^{4}}{\sqrt {\sec \left (d x + c\right )}} \,d x } \]
[In]
[Out]
Timed out. \[ \int \frac {(a+a \sec (c+d x))^4}{\sqrt {\sec (c+d x)}} \, dx=\int \frac {{\left (a+\frac {a}{\cos \left (c+d\,x\right )}\right )}^4}{\sqrt {\frac {1}{\cos \left (c+d\,x\right )}}} \,d x \]
[In]
[Out]